/*
 * @Author: 鏉滀簩搴� 3224811364@qq.com
 * @Date: 2024-07-01 14:23:56
 * @LastEditors: 鏉滀簩搴� 3224811364@qq.com
 * @LastEditTime: 2024-07-16 14:58:54
 * @FilePath: src/constants/index.ts
 * @Description: 这是默认设置,可以在设置》工具》File Description中进行配置
 */
// 常量
export const HOME_PATHNAME = '/'
export const LOGIN_PATHNAME = '/login'
export const REGISTER_PATHNAME = '/register'
export const MANAGE_INDEX_PATHNAME = '/manage/list'
export const LIST_SEARCH_PARAMS_KEY = 'keyword'
export const LIST_PAGE_SIZE = 10
export const LIST_PAGE_PARAM_KEY = 'page'
export const LIST_PAGE_SIZE_PARAM_KEY = 'pageSize'

export function isLoginOrRegister(pathname: string) {
  return [LOGIN_PATHNAME, REGISTER_PATHNAME].includes(pathname);
}

export function isNoNeedUserInfo(pathname: string) {
  if ([HOME_PATHNAME, LOGIN_PATHNAME, REGISTER_PATHNAME].includes(pathname)) {
    return true
  }
  return false

}
